package com.smmisia.redisson.config;

import org.springframework.boot.context.properties.ConfigurationProperties;

@ConfigurationProperties(prefix = "redisson")
public class RedissonProperties {

    private String address = "redis://2408:871a:b000:2::1:4614:6378"; // Default value
    private String password = "ststst1014";
    private Integer retryInterval = 1000;
    private Integer timeout = 3000;
    private Integer connectTimeout = 3000;

    public RedissonProperties(String address, String password, Integer retryInterval, Integer timeout, Integer connectTimeout) {
        this.address = address;
        this.password = password;
        this.retryInterval = retryInterval;
        this.timeout = timeout;
        this.connectTimeout = connectTimeout;
    }

    public RedissonProperties() {
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Integer getRetryInterval() {
        return retryInterval;
    }

    public void setRetryInterval(Integer retryInterval) {
        this.retryInterval = retryInterval;
    }

    public Integer getTimeout() {
        return timeout;
    }

    public void setTimeout(Integer timeout) {
        this.timeout = timeout;
    }

    public Integer getConnectTimeout() {
        return connectTimeout;
    }

    public void setConnectTimeout(Integer connectTimeout) {
        this.connectTimeout = connectTimeout;
    }
}
